package com.com.knowledgepaymentmanagementsystem.exception;

import com.com.knowledgepaymentmanagementsystem.utils.ResultUtil;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.RestControllerAdvice;

/**
 * @author 张攀
 * @version 1.0
 * @description: TODO
 * @date 2025/9/23 下午7:50
 */
@RestControllerAdvice
public class GlobalExceptionHandler {

    @ExceptionHandler(Exception.class)
    public ResultUtil exception(Exception exception){
        exception.printStackTrace();
        return new ResultUtil<>(500,"操作失败，请联系管理员");
    }
}
